home *** CD-ROM | disk | FTP | other *** search
/ Skunkware 98 / Skunkware 98.iso / src / net / bind-contrib.tar.gz / bind-contrib.tar / contrib / misc / dnstools.shar / README < prev   
Encoding:
Text File  |  1996-10-25  |  3.4 KB  |  109 lines

  1.  
  2.  
  3. This set of scripts is designed to make life a little
  4. easier for DNS adminitrators.
  5.  
  6. When you need to add delete or change hosts's information, you
  7. will only have to edit one file (the master name->IP addr database file
  8. often called named.hosts) and type 'make'.  The scripts
  9. will generate the reverse-lookup domain files, a new copy of
  10. /etc/hosts, run a consistency check to make sure that /etc/hosts and
  11. named.hosts match, signal bind to re-read the data files, and
  12. rdist the new /etc/hosts file to your client workstations.
  13.  
  14. Since there is a fair amount of lattitude in how you can
  15. set up BIND datafiles, here are the assumptions I operated under
  16. when writing these scripts:
  17.  
  18. 1. named.hosts contains your SOA record and all the 'forward'
  19. IP references (name to IP addr) for all your subnets.
  20.  
  21. 2. the reverse-lookup info (.inaddr.arpa) is kept in files
  22. one per subnet.
  23.  
  24. So your BIND bootfile (named.boot) might look something like this.
  25. (assuming you are blrfl.com and have three class C subnets-
  26. 128.2.30 thru 128.2.32)
  27.  
  28. primary         blrfl.com          named.hosts
  29. primary         30.2.128.in-addr.arpa        named.rev.128.2.30
  30. primary         31.2.128.in-addr.arpa        named.rev.128.2.31
  31. primary         32.2.128.in-addr.arpa        named.rev.128.2.32
  32.  
  33.  
  34.  
  35.  
  36. The files in this package:
  37. Makefile:  useful if you distribute /etc/hosts via rdist, not so
  38.     useful if you don't.
  39.  
  40. named-to-hosts: creates an /etc/hosts from named.hosts.  Requires dig
  41.     which is an incredibly useful tool that no DNS admin should be without.
  42.     Dig is available at many FTP sites, among them:
  43.     terminator.rs.itd.umich.edu:/unix/dns/dns-lookup-programs/dig
  44.     valhalla.ee.rochester.edu:/pub/src/dig
  45.  
  46. checkhosts: checks named.hosts against /etc/hosts, and reports
  47.     any inconsistencies- hosts in one file but not the other, or
  48.     hosts with incorrect IP addrs.
  49.  
  50. hosts-to-rev: creates reverse-lookup files (.inaddr.arpa) files from
  51.     the named.hosts file.
  52.  
  53. findip:    findip reads named.hosts and returns the next un-used IP address
  54.      in the class C subnet you specify.
  55.  
  56.  
  57. Installation:
  58.  
  59. Install the scripts in your DNS directory (often /etc/named.d or /etc).
  60. Or not.  Edit each one, there's some constants you will have to set in
  61. each.  The constants are at the top of each script.
  62.  
  63. Find, build and install dig if you don't have it.
  64. Edit the Makefile to set up an rdist of the /etc/hosts file if you
  65. want to do things that way.  If so, I recommend rdist6.x, a PD
  66. rdist available via ftp from usc.edu:/pub/rdist/rdist.tar.Z.
  67. This rdist is superior to the standard rdist, and 
  68. the current version (6.2) has an important security fix.
  69.  
  70.  
  71. Usage:
  72.  
  73. To add a new host:
  74.     Find an unused IP addr in the correct subnet:
  75.     ./findip <starting address>
  76.  
  77.     % ./findip 128.2.30.160
  78.     128.2.30.164
  79.  
  80.     In this case, 128.2.30.160 thru 128.2.30.163 were already taken, so
  81.     findip returned 128.2.30.164.
  82.  
  83.  
  84.     Edit named.hosts, add an A record (and CNAME and HINFO if desired)
  85.     for 128.2.30.164.
  86.  
  87.     Make.   Make will run hosts-to-rev and signal BIND to re-read
  88.     the new data files.  Then it will run named-to-hosts, and run
  89.     checkhosts on the resulting hosts file.  If it passes, it will run
  90.     an rdist to distribute the hosts file, if you have enabled rdist
  91.     in the Makefile.
  92.  
  93.  
  94. To change an existing hostname:
  95.     Change the hostname in the client's /etc/hosts, and
  96.     hostname.le0 or equivalent. 
  97.  
  98.     Change the name in named.hosts.
  99.  
  100.     Make (see above).  
  101.  
  102.  
  103. To delete an existing host:
  104.     Delete it from named.hosts.
  105.  
  106.     Make.
  107.  
  108.  
  109.